import { NgModule } from '@angular/core';
import { RouterModule, Routes } from '@angular/router';
import { FriendsIndexComponent } from './friends-index/friends-index.component';
import { EmptyFriendComponent } from './components/empty-friend/empty-friend.component';
import { ViewFriendComponent } from './components/view-friend/view-friend.component';

const routes: Routes = [
  {
    path: '',
    component: FriendsIndexComponent,
    children: [
      {
        path: '',
        component: EmptyFriendComponent,
      },
      {
        path: ':id',
        component: ViewFriendComponent,
      }
    ]
  }
]

@NgModule({
  imports: [RouterModule.forChild(routes)],
  exports: [RouterModule],
})
export class FriendsRoutingModule {}
